package org.huhu.mercury.dal.entity.sys;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;

@Entity
public class SystemUser {
	
	public static final int USER_STATUS_OK = 0;//正常
	public static final int USER_STATUS_lOCKED = 1;//停用
	public static final String USER_TYPE_OPERATOR = "OPERATOR";// 运营用户
	public static final String USER_TYPE_SYSADM = "SYSADM";// 系统管理员
	public static final String USER_TYPE_SUPPER = "SUPPER";//超级管理员
	 
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	private Long bossUserID;
	
	/**
	 * 用户昵称
	 */
	@Column(unique = true,nullable=false)
	private String username;
	
	/**
	 * 密码
	 */
	@Column(nullable=false)
	private String password;
	
	/**
	 * 手机号码
	 */
	@Column
	private String mobilePhone;
	
	/**
	 * 邮箱
	 */
	@Column
	private String email;
	
	/**
	 * 创建时间
	 */
	@Column
	private Date createTime;
	
	/**
	 * 修改时间
	 */
	@Column
	private Date updateTime;
	
	/**
	 * 修改人
	 */
	@Column
	private String updatePerson;
	
	/**
	 * 上次登录时间
	 */
	@Column
	private Date lastLoginTime;
	
	
	/**
	 * 用户角色    0：运营用户   1：系统管理员  2：超级管理员
	 */
	@Column(nullable=false)
	private String role;
	
	/**
	 * 用户状态   0：正常     1:停用
	 */
	@Column(nullable=false)
	private int userStatus;

	public Long getBossUserID() {
		return bossUserID;
	}

	public void setBossUserID(Long bossUserID) {
		this.bossUserID = bossUserID;
	}

	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getMobilePhone() {
		return mobilePhone;
	}

	public void setMobilePhone(String mobilePhone) {
		this.mobilePhone = mobilePhone;
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public Date getUpdateTime() {
		return updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	public String getUpdatePerson() {
		return updatePerson;
	}

	public void setUpdatePerson(String updatePerson) {
		this.updatePerson = updatePerson;
	}

	public Date getLastLoginTime() {
		return lastLoginTime;
	}

	public void setLastLoginTime(Date lastLoginTime) {
		this.lastLoginTime = lastLoginTime;
	}

	public String getRole() {
		return role;
	}

	public void setRole(String role) {
		this.role = role;
	}

	public int getUserStatus() {
		return userStatus;
	}

	public void setUserStatus(int userStatus) {
		this.userStatus = userStatus;
	}
	
}
